import requests
import json


def ding_talk(content):
    headers = {'Content-Type': 'application/json'}
    webhook = 'https://oapi.dingtalk.com/robot/send?access_token=52527f6d4d9d3ef35dbd82092f0c23ce482c6924d3fa74e07f8d7d174be2d426'
    data = {
        "msgtype": "text",
        "text": {
            "content": content
        }
    }
    requests.post(webhook, data=json.dumps(data), headers=headers)  # 发送post请求
